import request from '@/utils/request'

// 查询学生成绩记录列表
export function listExamrecord(query) {
  return request({
    url: '/teaching/examrecord/list',
    method: 'get',
    params: query
  })
}
// 查询上一次测试周数
export function queryLastWeek(params) {
  return request({
    url: '/teaching/examrecord/lastWeek',
    method: 'get',
    params: params
  })
}

// 查询学生成绩详情列表
export function listExamdetails(classesId) {
  return request({
    url: '/teaching/examdetail/list/'+classesId,
    method: 'get',
  })
}
// 查询学生成绩记录详细
export function getExamrecord(id) {
  return request({
    url: '/teaching/examrecord/' + id,
    method: 'get'
  })
}

// 新增学生成绩记录
export function addExamrecord(data) {
  return request({
    url: '/teaching/examrecord',
    method: 'post',
    data: data
  })
}

// 修改学生成绩记录
export function updateExamrecord(data) {
  return request({
    url: '/teaching/examrecord',
    method: 'put',
    data: data
  })
}

// 删除学生成绩记录
export function delExamrecord(id) {
  return request({
    url: '/teaching/examrecord/' + id,
    method: 'delete'
  })
}

export function detailList1(id){
  return request({
    url: '/teaching/examrecord/detail/' + id,
    method: 'get'
  })
}
